
#ifndef __HISOME_STREAM_MAIN_H__
#define __HISOME_STREAM_MAIN_H__
#include <stdint.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <sys/time.h>
#include <unistd.h>
#include <pthread.h>
#ifndef ARRAY_SIZE
#define ARRAY_SIZE(a)	(sizeof(a)/sizeof(a[0]))
#endif

#define __strncpy( d, s )  strncpy( d, s, sizeof(d)-1 )
#define __snprintf( str, fmt, args... ) snprintf( str, sizeof(str)-1, fmt, ##args)

#define  CONFIG_XESOE_SNDBUF_SIZE	(1<<20)
#define  CONFIG_XESOE_RCVBUF_SIZE	(1<<20)
struct cha_priv_struct {
	int tid;
	int ChaID;
	char s_fd;
	int send_sockfd;

	struct sockaddr_storage addr_peer;
	struct sockaddr_storage addr_local;

	char mode[32];
	char address[32];

    int error;
    FILE *pFd;

};
#endif //__HISOME_STREAM_MAIN_H__